# Author:liuqt
# week07

# 列表的真正意义的复制

# 1. 假复制 用 = 进行赋值  （错误的复制列表操作）
names = ["Mike","Mary","Jan","Jack"]
names_源文件 = names
names.append("liuqt")
print(names)
print(names_源文件)

# 2.真正意义上的复制（1）
names = ["Mike","Mary","Jan","Jack"]
names_源文件 = names.copy()
names.append("liuqt")
print(names)
print(names_源文件)

# 3.真正意义上的复制（2） 利用切片！
names = ["Mike","Mary","Jan","Jack"]
names_源文件 = names[:]
names.append("liuqt")
print(names)
print(names_源文件)
